Update Rust dependencies#802
Conversation
Signed-off-by: Patrick J.P. Culp <jpculp@amazon.com>
| # k8s-openapi must match the version required by kube and enable a k8s version feature | ||
| k8s-openapi = { version = "0.21", default-features = false, features = ["v1_24"] } | ||
| kube = { version = "0.88", default-features = false, features = [ "derive", "runtime", "rustls-tls" ] } | ||
| k8s-openapi = { version = "0.26", default-features = false, features = ["v1_30"] } |
There was a problem hiding this comment.
Although this is set to v1_30 (the oldest supported by k8s-openapi@0.26) I didn't have any issues updating a k8s 1.29 cluster.
There was a problem hiding this comment.
Kubernetes has a +/- 1 support story for the API, so 1.30 should work for 1.29.
We use very stable elements of the k8s API - theoretically very new versions of k8s could make changes that we don't support, but it is unlikely.
There was a problem hiding this comment.
The https://kubernetes.io/releases/version-skew-policy/ says slightly different - the controller/client should not be newer than the api-server. So technically there is no guaranteed compatibility between controllers under version 1.30 and api-server under 1.29.
Is it possible to pin it to 1_29 until we drop the 1.29 variants?
There was a problem hiding this comment.
I don't think that's necessary since we've confirmed the ability to update on a 1.29 cluster. Extended support does drop soon, but I don't think we should hold these updates back when we've validated the operator functionality.
624091d to
fcf974f
Compare
|
Addressed clippy warning. |
Signed-off-by: Patrick J.P. Culp <jpculp@amazon.com>
Signed-off-by: Patrick J.P. Culp <jpculp@amazon.com>
fcf974f to
0a27443
Compare
|
Updated CRDs. |
Updated cargo dependencies with minimal tweaks to reduce multiple versions. Signed-off-by: Patrick J.P. Culp <jpculp@amazon.com>
Signed-off-by: Patrick J.P. Culp <jpculp@amazon.com>
0a27443 to
1b15474
Compare
|
Bump |
| opentelemetry-instrumentation-actix-web = { version = "0.22", features = ["metrics"] } | ||
| opentelemetry-instrumentation-actix-web = { version = "0.23", features = ["metrics"] } | ||
|
|
There was a problem hiding this comment.
May be worth querying the metric endpoint to see that they are properly exposed.
There was a problem hiding this comment.
It looks like prometheus metrics are being properly exposed.
| pod_store.apply_watcher_event(&Event::Restarted(pods)); | ||
| pod_store.apply_watcher_event(&Event::Init); | ||
| for pod in pods { | ||
| pod_store.apply_watcher_event(&Event::InitApply(pod)); | ||
| } | ||
| pod_store.apply_watcher_event(&Event::InitDone); |
There was a problem hiding this comment.
Do you know what the context on this change is?
There was a problem hiding this comment.
There was an API change in the kube-runtime reflector store. Basically Event::Restarted was broken up into three phases.
| # k8s-openapi must match the version required by kube and enable a k8s version feature | ||
| k8s-openapi = { version = "0.21", default-features = false, features = ["v1_24"] } | ||
| kube = { version = "0.88", default-features = false, features = [ "derive", "runtime", "rustls-tls" ] } | ||
| k8s-openapi = { version = "0.26", default-features = false, features = ["v1_30"] } |
There was a problem hiding this comment.
Kubernetes has a +/- 1 support story for the API, so 1.30 should work for 1.29.
We use very stable elements of the k8s API - theoretically very new versions of k8s could make changes that we don't support, but it is unlikely.
| opentelemetry-instrumentation-actix-web = { workspace = true } | ||
| rustls = { workspace = true } | ||
| rustls-pemfile = { workspace = true } | ||
| webpki = { workspace = true } |
There was a problem hiding this comment.
What prompts this removal? Is it just marked as unused?
There was a problem hiding this comment.
Just unused. We could leave it but it adds an unnecessary dependency and we have to keep clarify.toml and deny.toml up to date to accommodate it.
| @@ -153,7 +153,7 @@ pub mod apiserver_error { | |||
|
|
|||
| #[snafu(display("Error creating prometheus registry: '{}'", source))] | |||
| PrometheusRegsitry { | |||
There was a problem hiding this comment.
Nit: we have some pre-existing typo...
| PrometheusRegsitry { | |
| PrometheusRegistry { |
There was a problem hiding this comment.
Since this is an already big change I'd like to save this for a separate PR.
| @@ -190,7 +190,7 @@ pub mod controller_error { | |||
|
|
|||
| #[snafu(display("Error creating prometheus registry: '{}'", source))] | |||
| PrometheusRegsitry { | |||
There was a problem hiding this comment.
Nit: we have pre-existing typo
| PrometheusRegsitry { | |
| PrometheusRegistry { |
| k8s-openapi = { version = "0.21", default-features = false, features = ["v1_24"] } | ||
| kube = { version = "0.88", default-features = false, features = [ "derive", "runtime", "rustls-tls" ] } | ||
| k8s-openapi = { version = "0.26", default-features = false, features = ["v1_30"] } | ||
| kube = { version = "2", default-features = false, features = [ "derive", "runtime", "rustls-tls" ] } |
There was a problem hiding this comment.
kube crate has a 3.0 now. Any concern if we further bump to that?
There was a problem hiding this comment.
We want to maintain compatibility with v1_30. Jumping to kube@3.0 only guarantees API compatibility with a minimum of v1_31.
Description of changes:
Updated various Rust dependencies including:
opentelemetryfrom 0.29 to 0.31.kubefrom 0.88 to 2.tokiofrom 1.46 to 1.47 LTS.bottlerocket-sdkfrom 0.65.0 to 0.70.0.Also removed unused
webpki.Testing done:
Terms of contribution:
By submitting this pull request, I agree that this contribution is dual-licensed under the terms of both the Apache License, version 2.0, and the MIT license.